package com.globalwave.filemanage.service;

import java.util.List;
import java.util.Set;

import com.globalwave.common.ArrayOrderList;
import com.globalwave.common.ArrayPageList;
import com.globalwave.filemanage.entity.Document;
import com.globalwave.filemanage.entity.DocumentCriterion;
import com.globalwave.filemanage.entity.SearchCriterion;

public interface DocumentService {
    
    public ArrayPageList<Document> query(
            DocumentCriterion fileCriterion, 
            int pageIndex, 
            int pageSize,
            ArrayOrderList orderList) 
    throws Exception ;
    
    public Document create(Document file) throws Exception ;
    public void update(Document file) throws Exception ;
    public void delete(Document file) throws Exception ;
    public void deleteAll(Long[] fileIds) throws Exception ;
    
    public List<Long> findDeletedDocIds() throws Exception ;
    public Set<Long> findDocIdByUserIdAndTag(Long userId, String tag) throws Exception ;
    //public Document get(Long id) throws Exception ;
    
    public ArrayPageList<Document> search(
    		SearchCriterion fileCriterion, 
            int pageIndex, 
            int pageSize) throws Exception ;

    
    public ArrayPageList<Document> listPhoto(
            DocumentCriterion fileCriterion, 
            int pageIndex, 
            int pageSize,
            ArrayOrderList orderList) 
    throws Exception ;
}
